package com.bangdream.michelia.utils;

/**
 * Created by Mr.Wang on 2018/2/24.
 * 909732184@qq.com
 */

public class ClickUtils {
    private final static String TAG = "ClickUtils";
    //段时间内只允许点击事件触发一次
    private static long lastClickTime = 0;
    public static boolean isFastDoubleClick() {
        MyLog.d(TAG,"上次点击的时间为："+lastClickTime);
        long time = System.currentTimeMillis();
        long timeD = time - lastClickTime;
        lastClickTime = time;
        MyLog.d(TAG,"当前点击的时间为："+time);
        MyLog.d(TAG,"当前点击的时间差为："+timeD);
        return timeD <= 200;
    }
}
